Skip to content

fix: WISH-453 Funding 및 Gift 서비스 리팩토링 및 이미지 매핑 로직 개선 #240

Merged
coding-jjun merged 6 commits intomainfrom
WISH-453-fundImgUrls-bugfix
Mar 9, 2025
Merged

fix: WISH-453 Funding 및 Gift 서비스 리팩토링 및 이미지 매핑 로직 개선 #240
coding-jjun merged 6 commits intomainfrom
WISH-453-fundImgUrls-bugfix

Conversation

@ChoiWheatley
Copy link
Collaborator

@ChoiWheatley ChoiWheatley commented Mar 8, 2025

Funding 및 Gift 서비스의 코드 최적화 및 불필요한 로직 정리

주요 변경 사항:

  1. Funding 서비스 개선

    • fundUser.image.imgUrlimageManager.getImages() 호출하지 않고 쿼리빌더 활용하여 성능 개선
  2. Gift 서비스 최적화

    • 기존 findAndCount() 대신 쿼리빌더 활용하여 성능 개선

기대 효과:

  • 불필요한 데이터 조회 최소화 (funding.user.image, gift.image)
  • 코드 가독성 및 유지보수성 향상
  • 성능 최적화

FROM

{
                "fundId": 1,
                "fundUuid": "6558a6b6-c7b9-4047-9f33-2292c6830ea4",
                "fundUserId": 12,
                "fundUserNick": "032",
                "fundTitle": "제 생일을 축하해주세요 🥳",
                "fundCont": "아이폰이 갖고 싶습니다,,,",
                "fundTheme": "Birthday",
                "fundPubl": true,
                "fundGoal": 1200000,
                "fundSum": 0,
                "fundAddrRoad": "경기 성남시 분당구 판교역로 166",
                "fundAddrDetl": "1층",
                "fundAddrZip": "13529",
                "fundRecvName": "홍영의",
                "fundRecvPhone": "01056019638",
                "fundRecvReq": "집 앞에 놓아주세요",
                "regAt": "2025-03-05T01:39:13.229Z",
                "endAt": "2025-03-28",
                "gifts": [
                    {
                        "giftId": 1,
                        "fundId": 1,
                        "giftUrl": "https://www.musinsa.com/products/4326317",
                        "giftTitle": "아이폰 15",
                        "giftOrd": 1,
                        "giftOpt": "화이트",
                        "giftCont": "",
                        "giftImg": "https://mblogthumb-phimHHlmGOyrr6htAuxPETsg.8JJSQNEA5HX2WmrshjZ-VjmJWqhmgE40Qm5csIud9VUg.JPEG.minziminzi128/IMG_7374.JPG?type=w800"
                    }
                ],
                "fundImgUrls": [],
                "fundUserImg": "http://t1.kakaocdn.net/account_images/default_profile.jpeg.twg.thumb.R110x110"
            }

AFTER

{
                "fundId": 1,
                "fundUuid": "6558a6b6-c7b9-4047-9f33-2292c6830ea4",
                "fundUserId": 12,
                "fundUserNick": "032",
                "fundTitle": "제 생일을 축하해주세요 🥳",
                "fundCont": "아이폰이 갖고 싶습니다,,,",
                "fundTheme": "Birthday",
                "fundPubl": true,
                "fundGoal": 1200000,
                "fundSum": 0,
                "fundAddrRoad": "경기 성남시 분당구 판교역로 166",
                "fundAddrDetl": "1층",
                "fundAddrZip": "13529",
                "fundRecvName": "홍영의",
                "fundRecvPhone": "01056019638",
                "fundRecvReq": "집 앞에 놓아주세요",
                "regAt": "2025-03-05T01:39:13.229Z",
                "endAt": "2025-03-28",
                "gifts": [
                    {
                        "giftId": 1,
                        "fundId": 1,
                        "giftUrl": "https://www.musinsa.com/products/4326317",
                        "giftTitle": "아이폰 15",
                        "giftOrd": 1,
                        "giftOpt": "화이트",
                        "giftCont": "",
                        "giftImg": "https://mblogthumb-phimHHlmGOyrr6htAuxPETsg.8JJSQNEA5HX2WmrshjZ-VjmJWqhmgE40Qm5csIud9VUg.JPEG.minziminzi128/IMG_7374.JPG?type=w800"
                    }
                ],
                "fundImgUrls": [ // <------------------ 추가됨!
                    "https://mblogthumb-phimHHlmGOyrr6htAuxPETsg.8JJSQNEA5HX2WmrshjZ-VjmJWqhmgE40Qm5csIud9VUg.JPEG.minziminzi128/IMG_7374.JPG?type=w800"
                ],
                "fundUserImg": "http://t1.kakaocdn.net/account_images/default_profile.jpeg.twg.thumb.R110x110"
            }

리뷰 부탁드립니다. 🚀

Copy link
Owner

@coding-jjun coding-jjun left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@coding-jjun coding-jjun merged commit ff92869 into main Mar 9, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants